from django.urls import re_path
from rest_framework.routers import SimpleRouter

from qas import views

urlpatterns = [
    re_path(r'^labels/$', views.LablesView.as_view()),
    re_path(r'^labels/users/$', views.LablesUsersView.as_view()),
    re_path(r'^user/label/$', views.UsersLablesView.as_view()),
    re_path(r'^labels/(?P<id>\d+)/focusin/$', views.LabelFocusin.as_view()),
    re_path(r'^labels/(?P<id>\d+)/focusout/$', views.LabelFocusout.as_view()),
    re_path(r'^labels/(?P<id>\d+)/$', views.LabelDetails.as_view()),
]

router = SimpleRouter()
router.register('questions', views.QuestionViewSet)
router.register('reply', views.ReplyViewSet)
urlpatterns += router.urls